<table id="tableList" class="table table-bordered table-striped tableList">
	<thead>
		<tr>
			<th>标题</th>
			<th>作者</th>
			<th>操作</th>
		</tr>
	</thead>
	<tbody>
	[#list page.content as article]
		<tr data-id="${article.id}" data-title="${article.title}">
			<td>${article.title}</td>
			<td>${article.author}</td>
			<td><button type="button" class="btn btn-info btn-xs" onclick="Page.chooseArticle(this)">选择</button></td>
		</tr>
	[/#list]
	</tbody>
</table>
<div id="pagingNode">
	
</div>
<script type="text/javascript">
	require(['public/js/paging', 'jquery'], function(Paging, $){
		// 分页
		var config = {
				page_info: {
					current_page: ${page.pageNumber}, // 当前页
					page_rows: ${page.pageSize}, // 每页记录数
					total_pages: ${page.totalPages}, // 总页数
					total_rows: ${page.total} //  总记录数
				},
				class_config: {
					page_word_skip_btn_c:'btn btn-primary btn-sm',
					page_number_wrap_c:'pagination',
					page_current_c:'active',
				},
				page_node: {
					$dom: $('#pagingNode')
				},
				success: function(data){
					var $formList = $('#formList');
					$formList.find('input[name=pageNumber]').val(data.number);
					$formList.find('input[name=pageSize]').val(data.page_rows);
					$formList.find('.btnSearch').click(); 
				}
		}
		Paging.paging(config);
	});
</script>